def fibonacci_iterative(n):
    if n == 0:
        return 0
    elif n == 1:
        return 1
    a, b = 0, 1
    for _ in range(2, n + 1):
        a, b = b, a + b
    return b
result = fibonacci_iterative(9)
print("斐波拉且数列的第9位数值为：",result)